#include "GrammarNode.h"
SK

GrammarNode::GrammarNode()
: command (""), type (GRAMMAR_OPTIONAL)
{
}

GrammarNode::GrammarNode(const String& command, GrammarType type)
:command (command),type(type)
{
}

GrammarNode::~GrammarNode()
{
    ChildGrammerNodes::iterator it;

    for (it = children.begin(); it != children.end(); it++)
        delete (*it);
}

GrammarNode *GrammarNode::addChild (GrammarNode *child)
{
    children.push_back (child);
    return child;
}



EK